const ADHUB_PREFIX = '/adhub-bff/api/v1/ad-hub'

export default [
  {
    path: '/',
    component: '../layouts/SecurityLayout',
    routes: [
      {
        path: '/',
        component: '../layouts/BasicLayout',
        routes: [
          {
            path: '/',
            redirect: '/dataManage',
          },
          // {
          //   path: '/dashboard',
          //   name: 'dashboard',
          //   icon: 'dashboard',
          //   component: './Dashboard',
          //   // authority: {
          //   //   anyOf: [
          //   //     [ADHUB_PREFIX + '/dashboard/usage-details', 'get'],
          //   //   ],
          //   // },
          // },
          {
            path: '/dataManage',
            name: 'dataManage',
            icon: 'DatabaseOutlined',
            routes: [
              {
                path: '/dataManage',
                redirect: '/dataManage/dataSet/list',
              },
              {
                path: '/dataManage/dataSet/list',
                name: 'dataSet',
                component: './DataSet/',
                // authority: {
                //   anyOf: [
                //     [ADHUB_PREFIX + '/datasets', 'get'],
                //   ],
                // },
              },
              {
                path: '/dataManage/dataSet/add',
                name: 'addDataSet',
                component: './DataSet/Add',
                // authority: {
                //   anyOf: [
                //     [ADHUB_PREFIX + '/unstructured-datasets', 'post'],
                //   ],
                // },
              },
              {
                path: '/dataManage/dataSet/detail/:id',
                name: 'detail',
                component: './DataSet/Detail',
                hideInMenu: true,
                // authority: {
                //   anyOf: [
                //     [ADHUB_PREFIX + '/datasets-collection/{id}', 'get'],
                //     [ADHUB_PREFIX + '/datasets-collection/{id}/versions', 'get'],
                //     [ADHUB_PREFIX + '/datasets/{id}/annots', 'get'],
                //   ],
                // },
              },
              {
                path: '/dataManage/dataSet/files/:id',
                name: 'files',
                component: './DataSet/Files',
                hideInMenu: true,
                // authority: {
                //   anyOf: [
                //     [ADHUB_PREFIX + '/datasets/{id}/file-directory', 'get'],
                //     [ADHUB_PREFIX + '/datasets/{id}/file-directory/file/:path', 'get'],
                //   ],
                // },
              },
              {
                component: '404',
              },
            ]
          },
          // {
          //   path: '/dataPoolManage',
          //   name: 'dataPoolManage',
          //   icon: 'ProjectOutlined',
          //   routes: [
          //     {
          //       path: '/dataPoolManage',
          //       redirect: '/dataPoolManage/list',
          //     },
          //     {
          //       path: '/dataPoolManage/list',
          //       name: 'list',
          //       component: './DataPool/List',
          //     },
          //     {
          //       path: '/dataPoolManage/add',
          //       name: 'add',
          //       component: './DataPool/Form',
          //     },
          //     {
          //       path: '/dataPoolManage/edit',
          //       name: 'edit',
          //       component: './DataPool/Form',
          //       hideInMenu: true,
          //     },
          //     {
          //       path: '/dataPoolManage/source',
          //       name: 'source',
          //       hideInMenu: true,
          //       routes: [
          //         {
          //           path: '/dataPoolManage/source/:id/list',
          //           name: 'list',
          //           component: './DataPool/DataSource/List',
          //         },
          //         {
          //           path: '/dataPoolManage/source/:id/add',
          //           name: 'add',
          //           component: './DataPool/DataSource/Form',
          //         },
          //         {
          //           path: '/dataPoolManage/source/:id/edit/:sourceId',
          //           name: 'edit',
          //           component: './DataPool/DataSource/Form',
          //         },
          //         {
          //           path: '/dataPoolManage/source/:id/detail/:sourceId',
          //           name: 'detail',
          //           component: './DataPool/DataSource/Detail',
          //         },
          //         {
          //           path: '/dataPoolManage/source/:id/view-data/:sourceId',
          //           name: 'viewData',
          //           component: './DataPool/DataSource/View',
          //         },
          //       ],
          //     },
          //     {
          //       component: '404',
          //     },
          //   ]
          // },
          {
            component: './404',
          },
        ],
      },
      {
        component: './404',
      },
    ],
  },
  {
    component: './404',
  },
];